A method for controlling an internal combustion engine having a camshaft whose phase can be adjusted with respect to a crankshaft by means of a setting mechanism is known from DE 101 08 055 C1. The setting mechanism disclosed in that publication is a hydraulic system by means of which the phase relationship between the crankshaft and the camshaft can be adjusted. Setting mechanisms of this type are widely used in modern internal combustion engines and are used on the one hand to improve performance and on the other hand to reduce emissions in the internal combustion engine.
With regard to the method known from DE 101 08 055 C1, near to the time when the internal combustion engine starts up a measurement value is determined for the phase between the crankshaft and the camshaft depending on sensed camshaft and crankshaft angles. A predefined initialization value is read in from a memory. The initialization value of the phase relationship is the value of the phase which the camshaft and the crankshaft have with respect to one another when all the mechanical components are arranged in the predefined manner with respect to one another. Such initialization values are typically fixed and predefined by the manufacturer of the internal combustion engine for all internal combustion engines of a series and stored in the control facilities provided for this purpose.
A correction value for the phase is then determined near to the time when the internal combustion engine starts up, depending on the difference between the initialization value and the measurement value for the phase. During the further operation of the internal combustion engine, the current phase in each case is then determined from the sum of the measurement value and the correction value. With regard to the known method, it is assumed that errors in the measurement value for the phase can essentially be attributed to the tolerances for the crankshaft sensor and the camshaft sensor. It has become apparent however that in spite of these corrections the desired low-emission operation of the internal combustion engine is not always guaranteed.